kmpkg_check_linkage(ONLY_STATIC_LIBRARY)

kmpkg_from_gitee(
    OUT_SOURCE_PATH SOURCE_PATH
    REPO "kumo-hub/LinuxTracepoints"
    REF "v${VERSION}"
    SHA512 43aff523f2bc43bc46e8c20c60d118c5541d62f597b058796a553c9f04f5c0e4b0de7d06d129fe766afa6b2121a1f0d52ac88b05969bff6390c5f511a37e3f09
    HEAD_REF main)

kmpkg_cmake_configure(
    SOURCE_PATH "${SOURCE_PATH}/libtracepoint-decode-cpp")

kmpkg_cmake_install()
kmpkg_copy_pdbs()
kmpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")

kmpkg_cmake_config_fixup(
    PACKAGE_NAME tracepoint-decode
    CONFIG_PATH lib/cmake/tracepoint-decode)

file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
